package djboom.materials.events {
	import flash.events.Event;

	/**
	 * .
	 * <br>
	 * 
	 * @author DJ BooM 
	 * @since 06.04.2010
	 * 
	 */

	public class InstructionEvent extends Event {

		// ----------------------------------------------------------------------------
		// Свойства класса.
		// ----------------------------------------------------------------------------

		public static const LIGHT_CELL:String = "lightCell";
		
		public static const REFRESH:String = "refresh";		public static const AUTO:String = "applyAuto";

		private var _cellName:String;		private var _methodName:String;

		// ----------------------------------------------------------------------------
		// Конструктор.
		// ----------------------------------------------------------------------------

		public function InstructionEvent(type:String, bubbles:Boolean = false, cancelable:Boolean = false) {
			super(type, bubbles, cancelable);
		}

		// ----------------------------------------------------------------------------
		// Публичные методы.
		// ----------------------------------------------------------------------------

		override public function clone():Event {
			var e:InstructionEvent = new InstructionEvent(this.type, this.bubbles, this.cancelable);
			e.cellName = this.cellName;			e.methodName = this.methodName;
			return e;
		}

		public function get cellName():String {
			return _cellName;
		}

		public function set cellName(cellName:String):void {
			_cellName = cellName;
		}
		
		public function get methodName():String {
			return _methodName;
		}
		
		public function set methodName(methodName:String):void {
			_methodName = methodName;
		}
	}
}